-
Notifications
You must be signed in to change notification settings - Fork 142
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add a CAPTCHA check during registration #460
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nmattia
force-pushed
the
nm-captcha-rebased
branch
3 times, most recently
from
November 23, 2021 14:43
66bc39b
to
1174d67
Compare
bitdivine
reviewed
Nov 25, 2021
nmattia
force-pushed
the
nm-captcha-rebased
branch
2 times, most recently
from
November 26, 2021 16:08
e1f230f
to
ceb5295
Compare
nmattia
requested review from
bitdivine,
roman-kashitsyn and
frederikrothenberger
November 26, 2021 16:16
Sorry about the size of this beast :( |
This was referenced Nov 29, 2021
frederikrothenberger
approved these changes
Nov 29, 2021
nmattia
force-pushed
the
nm-captcha-rebased
branch
from
November 29, 2021 14:59
6eb7b23
to
4bf0b3c
Compare
bitdivine
approved these changes
Nov 29, 2021
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
nmattia
force-pushed
the
nm-captcha-rebased
branch
2 times, most recently
from
December 3, 2021 09:44
79096ff
to
d258415
Compare
nmattia
force-pushed
the
nm-captcha-rebased
branch
from
December 6, 2021 14:00
d258415
to
8171f11
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This adds a CAPTCHA check during the registration flow. More precisely, the user now has to call the (new) method
create_challenge
that returns a CAPTCHA-style challenge (image and key) andregister
takes some extra parameters (the chars supposedly shown in the image, and the key). This involved some changes, in this repo and in others:create_challenge : () -> (Challenge);
with the corresponding "challenge" types:register
:register : (DeviceData, ProofOfWork, ChallengeResult) -> (RegisterResponse);
,register
frontend flow: the confirmation screen now shows a CAPTCHA,create_challenge()
call.dummy_captcha
feature (enabled in selenium tests and backend-tests) which makes sure the CAPTCHA challenges expect a known value ("a"
). This should of course NEVER be used in production, hence is opt-in.This also led to some helpful, though not absolutely necessary changes for backend-tests:
TODOs:
Add PoW tocreate_challenge
Differentiate a "bad captcha" error from an actual canister, unexpected error.Make the challenge key a string